package com.zahb.qadx.model;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * Created by Zdw on 2020/11/19 11:21
 * 题库列表
 * {
 * "id":40,
 * "questionLibId":null,
 * "name":"12312",
 * "rootOrgId":null,
 * "coverImage":null,
 * "cateId":29,
 * "introduce":null,
 * "price":null,
 * "onShelf":null,
 * "isDelete":null,
 * "creator":null,
 * "updator":null,
 * "createTime":null,
 * "updateTime":null,
 * "userName":null,
 * "cateName":null,
 * "questionCount":27,
 * "screenQuestionCount":6,
 * "questionLibRelationList":null
 * }
 */
public class QuestionBank implements Parcelable {

    private int id;
    private int questionLibId;
    private String name;
    private int rootOrgId;
    private String coverImage;
    private int cateId;
    private String introduce;
    private double price;
    private int onShelf;
    private int isDelete;
    private String userName;
    private String cateName;
    private int questionCount;
    private int screenQuestionCount;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public int getQuestionLibId() {
        return questionLibId;
    }

    public void setQuestionLibId(int questionLibId) {
        this.questionLibId = questionLibId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getRootOrgId() {
        return rootOrgId;
    }

    public void setRootOrgId(int rootOrgId) {
        this.rootOrgId = rootOrgId;
    }

    public String getCoverImage() {
        return coverImage;
    }

    public void setCoverImage(String coverImage) {
        this.coverImage = coverImage;
    }

    public int getCateId() {
        return cateId;
    }

    public void setCateId(int cateId) {
        this.cateId = cateId;
    }

    public String getIntroduce() {
        return introduce;
    }

    public void setIntroduce(String introduce) {
        this.introduce = introduce;
    }

    public double getPrice() {
        return price;
    }

    public void setPrice(double price) {
        this.price = price;
    }

    public int getOnShelf() {
        return onShelf;
    }

    public void setOnShelf(int onShelf) {
        this.onShelf = onShelf;
    }

    public int getIsDelete() {
        return isDelete;
    }

    public void setIsDelete(int isDelete) {
        this.isDelete = isDelete;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getCateName() {
        return cateName;
    }

    public void setCateName(String cateName) {
        this.cateName = cateName;
    }

    public int getQuestionCount() {
        return questionCount;
    }

    public void setQuestionCount(int questionCount) {
        this.questionCount = questionCount;
    }

    public int getScreenQuestionCount() {
        return screenQuestionCount;
    }

    public void setScreenQuestionCount(int screenQuestionCount) {
        this.screenQuestionCount = screenQuestionCount;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeInt(this.id);
        dest.writeInt(this.questionLibId);
        dest.writeString(this.name);
        dest.writeInt(this.rootOrgId);
        dest.writeString(this.coverImage);
        dest.writeInt(this.cateId);
        dest.writeString(this.introduce);
        dest.writeDouble(this.price);
        dest.writeInt(this.onShelf);
        dest.writeInt(this.isDelete);
        dest.writeString(this.userName);
        dest.writeString(this.cateName);
        dest.writeInt(this.questionCount);
        dest.writeInt(this.screenQuestionCount);
    }

    public QuestionBank() {
    }

    protected QuestionBank(Parcel in) {
        this.id = in.readInt();
        this.questionLibId = in.readInt();
        this.name = in.readString();
        this.rootOrgId = in.readInt();
        this.coverImage = in.readString();
        this.cateId = in.readInt();
        this.introduce = in.readString();
        this.price = in.readDouble();
        this.onShelf = in.readInt();
        this.isDelete = in.readInt();
        this.userName = in.readString();
        this.cateName = in.readString();
        this.questionCount = in.readInt();
        this.screenQuestionCount = in.readInt();
    }

    public static final Parcelable.Creator<QuestionBank> CREATOR = new Parcelable.Creator<QuestionBank>() {
        @Override
        public QuestionBank createFromParcel(Parcel source) {
            return new QuestionBank(source);
        }

        @Override
        public QuestionBank[] newArray(int size) {
            return new QuestionBank[size];
        }
    };
}
